package j02fanxingjiekou;

interface I1<K,T,V>{
    void f1(K k);
}

interface I2<K>{
    void f1(K k);
}

class C2 implements I2<String>{
    @Override
    public void f1(String s) {
        System.out.println("s = " + s);
    }
}

class C3<T> implements I2<T>{
    @Override
    public void f1(T t) {
        System.out.println("t = " + t);
    }
}

//声东击西
class C4<K> implements I2<K>{
    @Override
    public void f1(K t) {
        System.out.println("t = " + t);
    }
}

public class J1 {
    public static void main(String[] args) {
        new C2().f1("abc");

        C3<Integer> c3 = new C3<>();
        c3.f1(33);
        System.out.println("=====");
        new I2<Character>(){
            @Override
            public void f1(Character character) {
                System.out.println("character = " + character);
            }
        }.f1('w');
    }
}
